package studay.single;

/**
 * @program: 设计模式
 * @description: 饿汉方式实现单例模式
 * @author: Tom
 * @create: 2022-01-04 21:41
 **/
public class SingletonHungry {

    private static SingletonHungry instance = new SingletonHungry();
    private SingletonHungry(){}
    public static SingletonHungry getInstance(){
        return instance;
    }
}
